<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* 权重  标签选择器 > 类/伪类选择器 > id选择器 > 行内样式 >！import */
        div {
            color: red !important;
        }

        .king {
            color: blue;
        }

        :first-child {
            color: green;
        }

        #wang {
            color: pink;
        }
    </style>
</head>

<body>
    <div style="color: powderblue;" id="wang" class="king">王者农药</div>
</body>

</html>